/* 时间格式化 */
export const FormatTime = (val: number) => {
    const date: Date = new Date(val * 1000);
    const Y: string = date.getFullYear() + "-";
    const M: string =
        (date.getMonth() + 1 < 10
            ? "0" + (date.getMonth() + 1)
            : date.getMonth() + 1) + "-";
    const D: string = date.getDate() + " ";
    const h: string = date.getHours() + ":";
    const m: string = date.getMinutes() + ":";
    const s: number = date.getSeconds();
    return Y + M + D + h + m + s;
};